package com.kaigejava.studynote;

/**
 * @description
 * @since 2022/5/7 11:05
 */
public class SqlTest {

    public static void main(String[] args) {

    }

    public void gn(){
        String str = "36830774,41123641,25401972,10602571,44388251,44385472,44393552,44333031,44403622,44402751,10683911,44404631,44404401,44273572,44409721,44408422,42400072,43066462,44410401,24023452,38907271,44429672,44429452,42560991,44430402,40672261,44411001,44435492,44435772,44436022,44404672,44439631,43988441,44441862,44440291,44445152,44436862,44434362,44446251,44447171,44442862,44444722,44081751,44402712,44431381,44053731,42061702,44047222,44446192,44458322,44033982,10776261,44459232,44461592,11185212,44463231,44116131,44462062,44457402,44465432,44471982,44463821,44471261,44472442,44410482,44480422,44402151,44461852,35777721,41771751,41643912,44469812,44483881,44485802,43728061,11451781,41528341,44470752,44487082,43372271,44490082,44473691,44490922,44491861,44407552,44490451,43933061,44475302,44480481,44424112,44498562,44470161,44498851,44481951,44501091,44503242,44296561,44098261,40518701,44497852,44502942,44494712,44505461,44492681,44496521,44461732,44391211,42921381,40730192,44445191,40815632,44006491,44502432,44493772,44505282,44505872,44458671,44486001,44510192,44509281,44510311,43744191,44520742,44499351,44507261,44500021,40056062,41772511,44498112,44509032,44524632,44527012,44521852,44498251,44528351,44528622,44487382,44526261,44475182,44508362,44530731,25332891,22108852,44527161,44533642,44513652,44518842,11463461,44536102,43682971,10098052,44529512,44538021,24399322,44462491,44298471,44538412,44017622,44462401,44536292,44541251,41632151,44539332,44375831,44543811,44459712,43141471,44541632,23777072,44433901,44542251,44542922,44531741,11110531,44540971,42785411,44552101,22226141,44497872,44467012,22539371,42800211,44554681,44554571,44526151,44489492,44090631,43444201,44528062,44545401,23739891,44554991,44556221,44558361,44164082,43498272,44431902,10452241,40748882,44557082,44334352,44361311,44563502,44082402,44524872,42245821,44560051,44557491,44080791,43913401,41900431,44564512,43856801,44504472,23592981,43392581,44503171,44493612,44563411,44257832,44568111,43444242,44501131,44566141,44566942,11111282,44566511,43607521,44560531,21734841,44569721,44564722,44567892,44571661,42777542,36481712,44544271,44554222,44569682,35692412,41670471,44318611,44560361,44572041,44522461,11367592,44242242,44554262,44494771,44546681,10188732,42773721,42502682,42030732,44552371,44571822,44243771,44578841,10250782,44020531,44578372,44001762,44555171,44129152,42107942,44095931,44475531,41908551,21637261,44013911,44569061,44585311,44579852,44583911,40886331,44520561,44435551,44049041,44585271,44564612,42785122,43513272,44589762,40813672,44281112,44043861,44411781,43913212,21633552,44584332,36591031,44595161,43620892,40784851,44552221,42746762,42786231,40650441,43664922,44592091,44588321,44564751,44318411,44597111,44094862,42833692,36086711,24039082,44598642,44587292,43880822,43127352,44587002,41410981,10514042,41249921,10422462,44116411,23369551,22193921,44599032,43781591,10727701,41623511,41774432,42304881,10332962,44585681,44446172,44583111,44597982,41928041,42466152,43636482,44463881,10634632,44462982,44610481,38343971,24503522,44570832,44353092,44527382,43763922,41681801,23424211,44612012,44596092,44595741,44614391,43620561,44056521,44611881,44611742,43733872,42380552,43608431,44298682,44374301,44440742,44584191,44275261,43045462,44618231,44161881,41232821,44082821,10203821,41227991,44307422,42967772,41738512,23464652,44620211,44282951,41426741,44612961,44061491,43943642,40806942,21575022,43936952,44467601,42216952,44594501,43996521,43984602,42295661,43968541,41518962,42032362,44616062,43469382,44607562,44625681,43851002,43091162,37668651,23350841,43143032,40997052,21583522,43897591,44074131,21783271,10047291,44574181,36232482,22196662,43807532,43723682,10261701,43595611,41796282,42553121,42898181,44118922,43747101,44005052,44379221,41672381,11227482,11504492,42586491,35017122,44612782,44635042,10705061,25497181,44314402,43647372,44526542,10758992,40372841,10081602,44080841,44630361,44627782,22189711,44636161,21918441,44617221,44560621,42600601,43970042,24048522,43611911,44636362,44635332,21921581,43913761,44640592,10624482,44579502,44641411,42934201,44645721,43783031,44638081,44646911,41632102,44643161,44592962,41421042,44631071,42617992,44645522,44318381,44113092,44282862,23851202,44553142,44637302,44213411,44645901,38134191,42522731,41672712,43662811,43559802,36998352,43757831,40573162,44648772,38230631,44638181,44652552,42651921,44610791,41203842,43767932,42985111,44649931,44633571,43930212,25412162,44610962,44351542,42501531,44658281,44625131,44034511,44662882,44639352,44365532,44505191,36117221,43814901,44078502,44437031,44649681,44611932,42402462,22097532,21538752,10704571,44289102,41854481,43882791,44398842,44476181,10291542,43361472,44672861,22461272,44666372,44611761,44666602,44182711,10197812,43053942,44674491,41875001,40389461,44481181,44659151,44099541,43731341,44171951,44658081,44621821,35270111,44646671,43095542,41745822,42545841,24480981,44375581,36177491,44680202,43871041,24359842,42203002,44408291,44164382,41801471,23347301,43856612,44661322,44695191,44055572,44671532,44144012,22991732,44632932,44102492,44636301,44649652,35560652,39344382,10190052,44526772,44594081,44302332,44693381,44006862,41024352,44692641,44674192,25088881,44399022,24053072,23293872,44476862,44674321,44590241,43684752,22069362,42211962,42553682,44159692,44704092,36852142,44685392,44705152,36116842,21612121,44286011,44704002,44472702,44679012,44704191,43652482,44700031,41736781,44620952,44706212,41252872,44053432,44712561,24144992,44691881,44704311,40927801,44589642,24250602,44665442,42697732,44710111,44713751,43096761,37299282,44615181,21669511,44715802,44715982,44672382,44711292,23228001,44699252,44711291,43764431,44712072,43021841,40968242,43829752,44708392,10479191,24077311,44605632,44657882,43711981,44716561,44705831,44540071,44672322,44647932,44634332,42615111,44689801,44702131,11247441,41861222,43795631,40848841,44696462,44408181,44706812,44720832,43773411,44616252,10415462,24523481,44723982,44368291,43889872,44709722,43214422,44060002,37150712,44690331,44327961,21947862,44728582,42578912,42708531,40686642,41102671,41461052,38261342,44721411,44702531,44658962,44730242,11098321,44698852,22536481,44481622,44640321,38495131,44728461,43867592,43846551,44733731,43742522,44734861,43853692,21710891,43611361,44147072,25255642,38837392,44664271,36865021,42454121,44585122,44738331,44738732,44613382,43666231,44648222,36791232,41835732,44726222,43898622,42759152,42460951,42878491,44740661,44737361,44181881,44639952,44002711,44745452,44663802,44740912,44710341,44680951,44745282,40776471,44738161,44670201,44733652,44745612,43830481,43978772,43140171,24022121,43760762,39466242,44746651,35547001,44669471,38845912,44538291,44688951,44733531,42373052,44750581,43275372,11016362,37615082,40979182,43958581,44703662,40882921,42613332,25507311,44132882,22090692,44014351,43916621,25201132,35392821,44040552,44520802,44594162,43634671,44635422,24540511,44147362,44760861,44181022,40430222,43937832,44736581,42171132,41592081,44749271,44761852,44761611,44613861,44766871,44536131,10367631,23307722,44767441,44766002,42281361,37849751,41559371,44648771,44298522,44758592,37003712,22198421,44567542,44677131,44644742,44737561,40478441,10682521,44714112,43415532,44769441,44769391,44770482,44745112,43722972,43041212,44485611,44775972,44618721,44006251,44776812,44777242,42729771,44773282,44735982,44772581,43106842,44115751,44772652,43196732,44058501,44777081,44769671,10254042,22071522,10243882,44472072,42812682,44774751,43716802,44135901,10628812,42289702,44633132,41792472,40456982,35401082,42950822,44765192,43363201,38810952,44034621,44677311,44116361,44938694,44940553,44942214,44943964,44944254,44947813,44950743,44941243,44954233,44956413,44943683,44948083,44959843,44954334,44962453,44970383,44966824,35961121,44971034,44948463,44974273,44929633,44956433,44974723,44957064,44966063,44978543,44972133,44979044,44964224,44944223,11482792,44984564,44991333,44995004,44992733,44995724,44995203,44967103,45019154,45019494,44933323,45015814,44997303,45013604,45022973,44994253,45003994,45030444,45031043,45030733,44971624,44947094,45027653,45035673,45024093,44994283";

        String [] arr = str.split(",");
        for(String uid:arr){
            Long userId = Long.valueOf(uid);
            Long x = userId%1024;
            SqlInfo info = new SqlInfo();
            if(x<=255){
                info.setDbNo(0);
            }else if(x<=511){
                info.setDbNo(1);
            }else if(x<=767){
                info.setDbNo(2);
            }else if(x<=1023){
                info.setDbNo(3);
            }
            info.setTableNo(Integer.valueOf(x.toString()));
            info.setUserId(userId);
            String signSql = "SELECT user_id, count(*) from  hwyc_consume_0.b_recharge_h_240 where user_id = 22351088 and type =4  and ctime >= '2022-05-03 00:00:00' and ctime <= '2022-05-07 00:00:00' union all\n";
            //info.setSql();
        }

    }
}
